<template>
	<view class="padb30">
		<cu-custom bgColor="bg-gradual-blue" isBack>
			<block slot="content">用户信息</block>
			<block slot="backText">返回</block>
		</cu-custom>
		<div class="">
			<!-- <my-entity class="margin-top" v-model.sync="en.template" model="StreamPointTemplate" label="选择工艺" placeholder="请选择"></my-entity> -->
			<my-text class="margin-top" v-model="en.name" label="姓名" placeholder="真实姓名"></my-text>
			<my-text class="margin-top" v-model="en.phone" label="手机" placeholder="常用手机号"></my-text>
			<my-text-password class="margin-top" v-model="en.password" label="密码" placeholder="密码"></my-text-password>
			<sswitch class="margin-top" v-model="en.isOff" label="是否休班" placeholder="常用手机号"></sswitch>
			<!-- <my-date-time class="margin-top" v-model="text1" label="时间" ></my-date-time> -->
			<!-- <pic class="margin-top" v-model="en.cover" label="效果图" placeholder="设计总体效果图"></pic> -->
			<!-- <pics class="margin-top" v-model="en.pics" label="附件" placeholder="额外附件,可传多图"></pics> -->
			<mySubmit v-model="en" model="users"></mySubmit>
		</div>
	</view>
</template>

<script>
	import api from '../../../static/js/api.js'
	import com from '../../../static/js/com.js'
	import win from '../../../static/js/win.js'
	import list from '../../../static/js/list.js'
	
	import pics from '../../../com/component/pics.vue'
	import pic from '../../../com/component/pic.vue'
	import myEntity from '../../../com/component/myEntity.vue'
	import myText from '../../../com/component/myText.vue'
	import myTextPassword from '../../../com/component/myTextPassword.vue'
	import myTextarea from '../../../com/component/myTextarea.vue'
	import myDateTime from '../../../com/component/myDateTime.vue'
	import mySubmit from '../../../com/component/mySubmit.vue'
	export default {
		components:{
			pics,pic,myEntity,myText,myDateTime,myTextarea,mySubmit,myTextPassword
		},
		data() {
			return {
				en:{
					name:'',
					phone:'',
					password:'',
					isOff:false
				},
			}
		},
		methods: {
		},
		created() {
		},
		onLoad(option){
			let id = com.getLocData("user_id")
			let _this = this
			if(id != undefined){
				api.get("/api/user/info",{},(res)=>{
					// res.d.password = null
					_this.en = res.d
					// _this.en.password = null
				})
			}
		}
	}
</script>

<style>

</style>
